package zzu.websocket.jol;

import org.openjdk.jol.info.ClassLayout;

import java.util.ArrayList;
import java.util.List;

public class AboutObjectMemory {

    public static void main(String[] args) {
//        List<Animal> animals = new ArrayList(20000000);
//        for (int i = 0; i < 20000000; i++) {
//            Animal animal = new Animal();
//            animals.add(animal);
//        }
        System.out.print(ClassLayout.parseClass(Animal.class).toPrintable());
        System.out.print(ClassLayout.parseClass(test.class).toPrintable());
        System.out.print(ClassLayout.parseClass(Dept.class).toPrintable());
    }
}
